#pragma once

#include <Ogre.h>
#include "BtOgrePG.h"
#include "BtOgreGP.h"
#include "BtOgreExtras.h"

class BaseProjectile
{
public:
	BaseProjectile(Ogre::String name, Ogre::SceneManager* sceneMgr);
	~BaseProjectile(void);

	void tickCallBack();
	void updateProjectile(double timeSinceLastFrame);
	void updateTarget(Ogre::Vector3 target);
	bool getActiveState();
	void setActiveState(bool state);
	void resetProjectile(Ogre::Vector3 pPos, Ogre::Quaternion pOrientation);

	Ogre::SceneNode*			m_ProjectileNode;
	Ogre::Timer*					aliveTimer;
	long						aliveTimerMax;
private:


	Ogre::Vector3				m_TargetVector;
	Ogre::Entity*				m_ProjectileEntity;
	Ogre::Vector3				m_TranslateVector;
	Ogre::Vector3				m_RotateVector;
	Ogre::Real					m_MoveSpeed;
	Ogre::Real					m_RotateSpeed;
	float						m_MoveScale;
	float						m_RotScale;

	Ogre::SceneManager*			m_pSceneMgr;
	bool						isActive;
	int							m_MaxSpeed;
};
